FROM debian:testing

ENV TERM xterm-256color
ENV HOME /home/user
ENV LANG en_US.UTF-8
ENV LC_ALL C.UTF-8
ENV LANGUAGE en_US.UTF-8
ENV TIMEZONE America/Sao_Paulo

RUN apt-get update \
    && apt-get upgrade -y \
    && apt-get install -y \
      weechat \
      weechat-lua \
      weechat-perl \
      weechat-plugins \
      weechat-python \
      weechat-ruby \
      weechat-scripts \
      weechat-tcl \
      tor \
    && useradd -m -s /bin/bash -u 1000 user \
    && ln -fs /usr/share/zoneinfo/America/Sao_Paulo /etc/localtime \
    && dpkg-reconfigure --frontend noninteractive tzdata \
    && chown -R user:user $HOME

WORKDIR $HOME

USER user

CMD /usr/bin/tor >> /home/user/tor.log
